package verification

# read value from input.payload
get_payload(key) := v {
    v := object.get(input.payload, key, null)
} else := null

# read value from input.akcert.sce_no_as.payload
get_qta(key) := v {
    v := object.get(input.akcert.sce_no_as.payload, key, null)
} else := null

# export value
_base := {
    "version": get_payload("version"),
    "timestamp": get_payload("timestamp"),
    "scenario": get_payload("scenario"),
    "ta_uuid": get_payload("uuid"),
    "ta_mem": get_payload("ta_mem"),
    "ta_img": get_payload("ta_img"),
    "qta_mem": get_qta("qta_mem"),
    "qta_img": get_qta("qta_img"),
}

# output
result[k] := v {
    some k
    v := _base[k]
    v != null
}